#include <stdio.h>

#define MSIZE 128
#define dtom(x)  ((struct mbuf *)((int)(x) & ~(MSIZE-1)))

int main()
{
	//const char *str="123";
	//printf("str pointer contain :%p\n",str);
	//printf("str pointer address:%p\n",&str);

	struct mbuf {
		char str[20];
		int  data[108];
	};

	struct mbuf mb;
	printf("mbuf         contain:%p\n",&mb);
	printf("mbuf.data    address:%p\n",dtom(mb.data));

	int arr[] = {6, 7, 8, 9, 10};
	int *ptr = arr;

	(*ptr++) += 123;
	printf("%d,%d\n",*(++ptr),*ptr);
	//printf("%d,%d\n",*ptr,*(++ptr));

	char q[] = "amxyz";
	char *p = q;

	char be = *p;
	printf("%p=%c\n",p,be);
	char a = *p++;
	printf("%p=%c\n",p,a);
	char mi = *p;
	printf("%p=%c\n",p,mi);
	char c = (*p)++;
	printf("%p=%c\n",p,c);
	char af = *p;
	printf("%p=%c\n",p,af);
	//printf("%c,%c,%c,%c,%c,%s\n",be,a,mi,c,af,q);

	char e = *++p;
	printf("%p=%c\n",p,e);
	char f = *(++p);
	printf("%p=%c\n",p,f);
	char g = ++*p;
	printf("%p=%c\n",p,g);

}
